<html>
<head>
  <meta HTTP-EQUIV="Content-Type" CONTENT="text/html;charset=ISO-8859-1">
  <title>Contents.m</title>
<link rel="stylesheet" type="text/css" href="../../stpr.css">
</head>
<body>
<table  border=0 width="100%" cellpadding=0 cellspacing=0><tr valign="baseline">
<td valign="baseline" class="function"><b class="function">RSDE</b>
<td valign="baseline" align="right" class="function"><a href="../../probab/estimation/index.html" target="mdsdir"><img border = 0 src="../../up.gif"></a></table>
  <p><b>Reduced Set Density Estimator.</b></p>
  <hr>
<div class='code'><code>
<span class=help></span><br>
<span class=help>&nbsp;<span class=help_field>Synopsis:</span></span><br>
<span class=help>&nbsp;&nbsp;model&nbsp;=&nbsp;rsde(X,options)</span><br>
<span class=help></span><br>
<span class=help>&nbsp;<span class=help_field>Description:</span></span><br>
<span class=help>&nbsp;&nbsp;This&nbsp;function&nbsp;implements&nbsp;the&nbsp;Reduced&nbsp;Set&nbsp;Density&nbsp;Estimator&nbsp;</span><br>
<span class=help>&nbsp;&nbsp;[<a href="../../references.html#Girol03" title = "" >Girol03</a>]&nbsp;which&nbsp;provides&nbsp;kernel&nbsp;density&nbsp;estimate&nbsp;optimal&nbsp;</span><br>
<span class=help>&nbsp;&nbsp;in&nbsp;the&nbsp;L2&nbsp;sense.&nbsp;The&nbsp;density&nbsp;is&nbsp;modeled&nbsp;as&nbsp;the&nbsp;weighted&nbsp;sum&nbsp;</span><br>
<span class=help>&nbsp;&nbsp;of&nbsp;Gaussians&nbsp;(RBF&nbsp;kernel)&nbsp;centered&nbsp;in&nbsp;selected&nbsp;subset&nbsp;of&nbsp;</span><br>
<span class=help>&nbsp;&nbsp;training&nbsp;data.&nbsp;</span><br>
<span class=help></span><br>
<span class=help>&nbsp;&nbsp;The&nbsp;estimation&nbsp;is&nbsp;expressed&nbsp;as&nbsp;a&nbsp;special&nbsp;instance&nbsp;of&nbsp;the</span><br>
<span class=help>&nbsp;&nbsp;Quadratic&nbsp;Programming&nbsp;task&nbsp;(see&nbsp;'help&nbsp;gmnp').</span><br>
<span class=help>&nbsp;&nbsp;</span><br>
<span class=help>&nbsp;<span class=help_field>Input:</span></span><br>
<span class=help>&nbsp;&nbsp;X&nbsp;[dim&nbsp;x&nbsp;num_data]&nbsp;Input&nbsp;data&nbsp;sample.</span><br>
<span class=help>&nbsp;&nbsp;options&nbsp;[struct]&nbsp;Control&nbsp;parameters:</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;.arg&nbsp;[1x1]&nbsp;Standard&nbsp;deviation&nbsp;of&nbsp;the&nbsp;Gaussian&nbsp;kernel.</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;.solver&nbsp;[string]&nbsp;QP&nbsp;solver&nbsp;(see&nbsp;'help&nbsp;gmnp');&nbsp;'imdm'&nbsp;default.</span><br>
<span class=help></span><br>
<span class=help>&nbsp;<span class=help_field>Output:</span></span><br>
<span class=help>&nbsp;&nbsp;model&nbsp;[struct]&nbsp;Output&nbsp;density&nbsp;model:</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;.Alpha&nbsp;[nsv&nbsp;x&nbsp;1]&nbsp;Weights&nbsp;of&nbsp;the&nbsp;kernel&nbsp;functions.</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;.sv.X&nbsp;[dim&nbsp;x&nbsp;nsv]&nbsp;Selected&nbsp;centers&nbsp;of&nbsp;kernel&nbsp;functions.</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;.nsv&nbsp;[1x1]&nbsp;Number&nbsp;of&nbsp;selected&nbsp;centers.</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;.options.arg&nbsp;=&nbsp;options.arg.</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;.options.ker&nbsp;=&nbsp;'rbf'</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;.stat&nbsp;[struct]&nbsp;Statistics&nbsp;about&nbsp;optimization:</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;.access&nbsp;[1x1]&nbsp;Number&nbsp;of&nbsp;requested&nbsp;columns&nbsp;of&nbsp;matrix&nbsp;H.</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;.t&nbsp;[1x1]&nbsp;Number&nbsp;of&nbsp;iterations.</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;.UB&nbsp;[1x1]&nbsp;Upper&nbsp;bound&nbsp;on&nbsp;the&nbsp;optimal&nbsp;value&nbsp;of&nbsp;criterion.&nbsp;</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;.LB&nbsp;[1x1]&nbsp;Lower&nbsp;bound&nbsp;on&nbsp;the&nbsp;optimal&nbsp;value&nbsp;of&nbsp;criterion.&nbsp;</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;.LB_History&nbsp;[1x(t+1)]&nbsp;LB&nbsp;with&nbsp;respect&nbsp;to&nbsp;iteration.</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;.UB_History&nbsp;[1x(t+1)]&nbsp;UB&nbsp;with&nbsp;respect&nbsp;to&nbsp;iteration.</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;.NA&nbsp;[1x1]&nbsp;Number&nbsp;of&nbsp;non-zero&nbsp;entries&nbsp;in&nbsp;solution.</span><br>
<span class=help>&nbsp;&nbsp;&nbsp;</span><br>
<span class=help>&nbsp;<span class=help_field>Example:</span></span><br>
<span class=help>&nbsp;&nbsp;gnd&nbsp;=&nbsp;struct('Mean',[-2&nbsp;3],'Cov',[1&nbsp;0.5],'Prior',[0.4&nbsp;0.6]);</span><br>
<span class=help>&nbsp;&nbsp;sample&nbsp;=&nbsp;gmmsamp(&nbsp;gnd,&nbsp;1000&nbsp;);</span><br>
<span class=help>&nbsp;&nbsp;figure;&nbsp;hold&nbsp;on;&nbsp;ppatterns(sample.X);</span><br>
<span class=help>&nbsp;&nbsp;plot([-4:0.1:8],&nbsp;pdfgmm([-4:0.1:8],gnd),'r');</span><br>
<span class=help></span><br>
<span class=help>&nbsp;&nbsp;model&nbsp;=&nbsp;rsde(sample.X,struct('arg',0.7));</span><br>
<span class=help>&nbsp;&nbsp;x&nbsp;=&nbsp;linspace(-4,8,100);</span><br>
<span class=help>&nbsp;&nbsp;plot(x,kernelproj(x,model),'g');&nbsp;</span><br>
<span class=help>&nbsp;&nbsp;ppatterns(model.sv.X,'ob',13);</span><br>
<span class=help>&nbsp;&nbsp;Reduction&nbsp;=&nbsp;model.nsv/size(sample.X,2)</span><br>
<span class=help></span><br>
<span class=help>&nbsp;<span class=also_field>See also </span><span class=also></span><br>
<span class=help><span class=also>&nbsp;&nbsp;<a href = "../../kernels/kernelproj.html" target="mdsbody">KERNELPROJ</a>,&nbsp;<a href = "../../probab/estimation/emgmm.html" target="mdsbody">EMGMM</a>,&nbsp;<a href = "../../probab/estimation/mlcgmm.html" target="mdsbody">MLCGMM</a>,&nbsp;GMNP.</span><br>
<span class=help></span><br>
</code></div>
  <hr>
  <b>Source:</b> <a href= "../../probab/estimation/list/rsde.html">rsde.m</a>
  <p><b class="info_field">About: </b>  Statistical Pattern Recognition Toolbox<br>
 (C) 1999-2005, Written by Vojtech Franc and Vaclav Hlavac<br>
 <a href="http://www.cvut.cz">Czech Technical University Prague</a><br>
 <a href="http://www.feld.cvut.cz">Faculty of Electrical Engineering</a><br>
 <a href="http://cmp.felk.cvut.cz">Center for Machine Perception</a><br>

  <p><b class="info_field">Modifications: </b> <br>
 24-jan-2005, VF, Fast QP solver (GMNP) was used instead of QUADPROG.<br>
 17-sep-2004, VF, revised<br>

</body>
</html>
